package report

import grails.test.*

class PlanTests extends GrailsUnitTestCase {
	
	private int year = 2001
	private String observation = "nenhuma"  
	
	protected void setUp() {
        super.setUp()
    }

    protected void tearDown() {
        super.tearDown()
    }
    void testValues() {
    	def p = new Plan(year:year, observation:observation)
    	assertEquals year, p.year
    	assertEquals observation, p.observation
    }
    
    void testConstraints() {
    	def p = new Plan();
    	mockForConstraintsTests(Plan, [p])
    	
    	assertFalse p.validate()
    }
}
